userAgent

public abstract String userAgent()

Returns a string that represents the user-agent of the current browser instance.

The user-agent string can be overridden for each browser instance via userAgent. If the string has not been overridden, then this method returns the default user-agent string obtained through userAgent.

See also

Throws

when the browser is already closed


public abstract void userAgent(String userAgent)

Updates the user-agent string of the current browser instance and reloads the currently loaded web page.

Parameters

userAgent

a new user-agent string

Throws

when the browser is already closed

when userAgent is empty or blank